
/*
This file is part of Docking@Home.
http://docking.gcl.cis.udel.edu
Copyright (C) 2009 University of Delaware

Docking@Home is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

Docking@Home is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with Docking@Home.  If not, see <http://www.gnu.org/licenses/>.
*//*
	Filename: TabWindow.h
	Description: Contains information about where on the screen a tab can
		render the information it is supposed to contains. 
	Revision History: 
		Created - 01/03/08
	Author: Robert Keller (01/03/08 -> current)
*/

#ifndef _TabWindow_h
#define _TabWindow_h

#include "../GLHelper.h"

class TabWindow
{

public:

	// Constructor / Destructor

	TabWindow ();
	~TabWindow ();

	// Member Modifiers

	void setWindowWidth (int w);
	void setWindowHeight (int h);

	void setLogoOffset (int h);

	void resetCorners ();

	void setBorderColor (const float color[4]);

	// Member Accessors

	int getWindowWidth () const;
	int getWindowHeight () const;

	int getTopLeftX () const;
	int getTopLeftY () const;

	int getBottomRightX () const;
	int getBottomRightY () const;

	int getMiddleX () const;

	float getWidthFactor () const;
	float getHeightFactor () const;

	// Render Functions

	void draw ();

	// Window Size Constants used to produce 
	// ratios for scaling
	const int STANDARD_WIDTH;
	const int STANDARD_HEIGHT;

private:

	// Need window size to determine drawing area
	int windowWidth;
	int windowHeight;

	// Needed since we must position this window below it
	int logoOffset;

	// Render Variables

	float borderColor[4];

	// Corners of the window
	int topLeftX;
	int topLeftY;
	int bottomRightX;
	int bottomRightY;

	int middleX;

	// Sizing Factor
	float widthFactor;
	float heightFactor;

	// Positioning constants

	const int PADDING_LEFT;
	const int PADDING_RIGHT;
	const int PADDING_TOP;
	const int PADDING_BOTTOM;

	// Rendering Helper

	static GLHelper * glHelper;
};

#endif
